/////////////////////////////////////////////////////////////////////////////
/*/	
 *	Creator:		Joshua C. Rouzer
 *	Title:			
 *	Last Edited:	06/11/2013
 *	Summary:		
/*/
/////////////////////////////////////////////////////////////////////////////
#ifndef CANIMSYSTEM_H
#define CANIMSYSTEM_H
#include "AnchorPointAnimation.h"
#include <vector>
#include <Windows.h>
using namespace std;

class CSGD_Direct3D;
class CSGD_TextureManager;
class CSGD_DirectInput;
class CSGD_XAudio2;

class CAnimationSystem
{
private:
	vector<CAnchorPointAnimation*> m_vAnimations;

	CSGD_Direct3D*			m_pD3D;
	CSGD_DirectInput*		m_pDI;
	CSGD_TextureManager*	m_pTM;
	CSGD_XAudio2*			m_pXA;

	void CheckCollision(CAnimInfo* Info);
	bool IsEmpty(RECT* toCheck);

	bool CollisionMsg;

public:
	CAnimationSystem(void);
	~CAnimationSystem(void);

	void LoadAnimation(string FilePath);

	void Update(float fElapsedTime,CAnimInfo* Info);
	void Render(SPosition Pos, CAnimInfo* Info, float fScale = 1);

	std::vector<CAnchorPointAnimation*> GetAnimations();
	int FindAnimation( string name );
};
#endif